﻿@using ZhongKeSite.Entity
@{
    ViewBag.Title = "新增里程碑";
}
@model MileStone
<style>
    html {
        background-color: #fff;
    }

    .layui-card {
        box-shadow: none;
    }
</style>

<div class="layui-card">
    <div class="layui-card-body">
        <form class="layui-form" action="@Url.Action("MileStoneAdd","MileStone",new { area = "Admin"})" lay-filter="useradd-form">
            <div class="layui-form-item">
                <label class="layui-form-label">标题*</label>
                <div class="layui-input-block">
                    <input type="text" name="Title" lay-verify="required" placeholder="标题" autocomplete="on" class="layui-input">
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">所属类型*</label>
                <div class="layui-input-block">
                    <select name="MileStoneType" lay-filter="MileStoneType">
                        @foreach (var item in (IEnumerable<SelectListItem>)ViewBag.MileStoneTypeDLL)
                        {
                            <option value="@item.Value">@item.Text</option>
                        }
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">发布时间*</label>
                <div class="layui-input-block">
                    <input type="text" id="publishDate" lay-verify="required" name="PublishDate" placeholder="发布时间" autocomplete="on" class="layui-input">
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">内容*</label>
                <div class="layui-input-block">
                    <textarea type="text" class="layui-textarea" lay-verify="required" name="Content" placeholder="内容"></textarea>
                </div>
            </div>
            <div id="useradd-submit" lay-submit lay-filter="useradd-submit"></div>
        </form>
    </div>
</div>
<script>
    layui.use(['laydate','form'], function () {
        var $ = layui.$, form = layui.form;
        var laydate = layui.laydate;
        //执行一个laydate实例
        laydate.render({
            elem: '#publishDate' //指定元素
        });
        form.render(null, 'useradd-form');
    });
</script>
